package com.bookcloud.java21.chapter5.返回对象54;

public class CreateFactory {
  public Point createPoint(int x, int y) {
    return new Point(x, y);
  }

  public void movePoint(Point p, int x, int y) {
    // 把传递过来的对象进行修改
    p.setX(x);
    p.setY(y);
  }
}
